<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>流式布局</title>
    <style>
        .content {
            display: flex;
            width: 200px;
            height: 400px;
            flex-flow: row wrap;
            align-content: flex-start;
            border: 1px solid #222;
            box-sizing: border-box;
        }

        .content .box {
            width: 25%;
            height: 50px;
            border-right: 1px solid #222;
            border-bottom: 1px solid #222;
            box-sizing: border-box;
        }
        .content .box:nth-child(4n){
            border-right: 0;
        }
    </style>
</head>
<body>
<div class="content flow">
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
    <div class="box"></div>
</div>
</body>
</html>